from building import *

cwd = GetCurrentDir()

Import('asenv')
ASROOT = asenv['ASROOT']

if(IsPlatformWindows()):
    asenv.Append(CPPDEFINES=['__WINDOWS__'])
else:
    asenv.Append(CPPDEFINES=['__LINUX__'])

asenv.Append(CPPDEFINES=['__AS_BY_PARAI__', 'LUA_COMPAT_5_2', 'LUA_COMPAT_5_1'])

MODULES = ['LUA',
           'LUA_ASLIB',
           'LUA_DEV','LUA_DEV_RS232',
           'LUA_DEV_LIN','LUA_DEV_LIN_SOCKET',
           'LUA_CAN','LUA_SERIAL_CAN','LUA_SOCKET_CAN',
           'DET','SHELL',
           ]

if(IsPlatformWindows()):
    MODULES += ['LUA_PEAK_CAN','LUA_ZLG_CAN','LUA_VXL_CAN']

if(asenv['MODULES'] is None):
    asenv['MODULES'] = MODULES
else:
    MODULES = asenv['MODULES']

MODULES.append('ANYOS')

asenv['ARCH'] = 'host'

asenv.Append(LIBS=['pthread', 'm' , 'stdc++'])

objs = []

Return('objs')
